package com.ruoyi.chain.purchase.domain;

import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.math.BigDecimal;
import java.util.Date;

/**
 * 采购对象 t_chain_purchase
 *
 * @author Shawn
 * @date 2024-02-26
 */
@Data
public class ChainPurchase extends BaseEntity {
    private static final long serialVersionUID = 1L;

    /**
     * 主键
     */
    @Schema(name = "主键")
    private Long id;

    /**
     * 合作公司ID
     */
    @Schema(name = "合作公司ID")
    @Excel(name = "合作公司商品ID")
    private Long cooCommodityId;

    @Schema(name = "用户ID")
    private Long userId;

    /**
     * 采购人
     */
    @Schema(name = "采购人")
    private String userName;

    @Schema(name = "合作公司ID")
    private Long cooperationId;

    @Schema(name = "合作公司名称")
    private String cooperationName;

    @Schema(name = "商品ID")
    private Long commodityId;
    @Schema(name = "商品名称")
    private String commodityName;

    @Schema(name = "图片地址")
    private String image;


    /**
     * 数量
     */
    @Excel(name = "数量")
    @Schema(name = "商品数量")
    private Long quantity;

    /**
     * 金额
     */
    @Schema(name = "金额")
    @Excel(name = "金额")
    private BigDecimal amount;

    @Schema(name = "审核状态")
    @Excel(name = "审核类型")
    private Long auditType;

    @Schema(name = "审核信息")
    @Excel(name = "审核信息")
    private String auditInfo;

    /**
     * 运输方式
     */
    @Excel(name = "运输方式")
    @Schema(name = "运输方式")
    private Long transportType;

    /**
     * 运送状态
     */
    @Schema(name = "运送状态")
    @Excel(name = "运送状态")
    private Long transportStatus;

    /**
     * 乐观锁
     */
    private Long REVISION;

    /**
     * 创建人
     */
    @Schema(name = "创建人")
    private String createdBy;

    /**
     * 创建时间
     */
    @Schema(name = "创建时间")
    private Date createdTime;

    /**
     * 更新人
     */
    @Schema(name = "更新人")
    private String updatedBy;

    /**
     * 更新时间
     */
    @Schema(name = "更新时间")
    private Date updatedTime;

    @Schema(name = "质检状态",description = "0=待检验,1=合格,2=不合格")
    @Excel(name = "质检状态", readConverterExp = "0=待检验,1=合格,2=不合格")
    private Integer inspectionStatus;

    @Schema(name = "合格数量")
    @Excel(name = "合格数量")
    private Long qualifiedQuantity;

    @Schema(name = "校验时间")
    @Excel(name = "校验时间")
    private Date inspectionTime;

    @Schema(name = "校验人id")
    @Excel(name = "校验ID")
    private Long inspectorId;

    @Schema(name = "退货原因")
    @Excel(name = "退货原因")
    private String returnReason;
}
